Batch Masking Data
This API masks multiple plaintext values using a single masking function in one request. The masking function is identified by its unique function_id, and the API returns the masked data for each plaintext.
Endpoint Details
| URL | /v1/masking/batch |
| Method | POST |
| Authorization | Bearer Token |
Request Headers
| Header | Type | Description |
|---|---|---|
| Content-Type | String | Must be application/json |
Request Body
Use the following format to make a request:
JSON Request
{
"function_id": "64c72efa-762d-424a-bd10-f54630976c42",
"plaintexts": [
"082167588218",
"kalimantan"
]
}
Parameters
| Parameter | Type | Description |
|---|---|---|
| function_id | UUID | Unique identifier of the masking function used to perform masking |
| plaintexts | Array | List of plaintext values to be masked using the specified masking function |
Response
Here is an example response after the request has been successfully processed:
Response
{
"masked_data": [
"08######8218",
"ka####ntan"
]
}
Field Descriptions
| Field | Type | Description |
|---|---|---|
| masked_data | Array | List of masked results in the same order as the input plaintexts |
info
- A valid Bearer Token is required to access this endpoint.
- The
function_idmust refer to an existing masking function. - All plaintext values in a single request are masked using the same masking function.
- The
masked_dataarray preserves the same order as theplaintextsprovided in the request.